def is_balanced(n, a):
    total_sum = sum(a)
    left_sum = 0
    for i in range(n - 1):
        left_sum += a[i]
        right_sum = total_sum - left_sum
        if left_sum == right_sum:
            return "Yes"
    return "No"

t = int(input())
for _ in range(t):
    n = int(input())
    a = list(map(int, input().split()))
    print(is_balanced(n, a))